package com.jbm.onehome.iface;

import javax.persistence.*;
import com.jbm.core.iface.IAcross;
import java.sql.Timestamp;

/**
 * Created by lyh on 2017-02-24.
 */
@Entity
@Table(name = "bus_audit_log", schema = "", catalog = "")
@org.hibernate.annotations.Entity(dynamicUpdate=true,dynamicInsert=true)
public class BusAuditLogEntity extends IAcross
{
	public BusAuditLogEntity()
	{
		super();
	}

	public BusAuditLogEntity(IAcross ia)
	{
		super(ia);
	}


    private static final long serialVersionUID = 6417146100232055968L;
    private int auditId;
    private Integer busId;
    private Timestamp cerateDate;
    private Timestamp auditdate;
    private Integer auditLoginId;
    private Integer result;
    private String refuseinfo;

    @Id
    @GeneratedValue
    @Column(name = "audit_id")
    public int getAuditId() {
        return auditId;
    }

    public void setAuditId(int auditId) {
        this.auditId = auditId;
    }

    @Basic
    @Column(name = "bus_id")
    public Integer getBusId() {
        return busId;
    }

    public void setBusId(Integer busId) {
        this.busId = busId;
    }

    @Basic
    @Column(name = "cerate_date")
    public Timestamp getCerateDate() {
        return cerateDate;
    }

    public void setCerateDate(Timestamp cerateDate) {
        this.cerateDate = cerateDate;
    }

    @Basic
    @Column(name = "auditdate")
    public Timestamp getAuditdate() {
        return auditdate;
    }

    public void setAuditdate(Timestamp auditdate) {
        this.auditdate = auditdate;
    }

    @Basic
    @Column(name = "audit_login_id")
    public Integer getAuditLoginId() {
        return auditLoginId;
    }

    public void setAuditLoginId(Integer auditLoginId) {
        this.auditLoginId = auditLoginId;
    }

    @Basic
    @Column(name = "result")
    public Integer getResult() {
        return result;
    }

    public void setResult(Integer result) {
        this.result = result;
    }

    @Basic
    @Column(name = "refuseinfo")
    public String getRefuseinfo() {
        return refuseinfo;
    }

    public void setRefuseinfo(String refuseinfo) {
        this.refuseinfo = refuseinfo;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) return true;
        if (o == null || getClass() != o.getClass()) return false;

        BusAuditLogEntity that = (BusAuditLogEntity) o;

        if (auditId != that.auditId) return false;
        if (auditLoginId != null ? !auditLoginId.equals(that.auditLoginId) : that.auditLoginId != null) return false;
        if (auditdate != null ? !auditdate.equals(that.auditdate) : that.auditdate != null) return false;
        if (busId != null ? !busId.equals(that.busId) : that.busId != null) return false;
        if (cerateDate != null ? !cerateDate.equals(that.cerateDate) : that.cerateDate != null) return false;
        if (refuseinfo != null ? !refuseinfo.equals(that.refuseinfo) : that.refuseinfo != null) return false;
        if (result != null ? !result.equals(that.result) : that.result != null) return false;

        return true;
    }

    @Override
    public int hashCode() {
        int result1 = auditId;
        result1 = 31 * result1 + (busId != null ? busId.hashCode() : 0);
        result1 = 31 * result1 + (cerateDate != null ? cerateDate.hashCode() : 0);
        result1 = 31 * result1 + (auditdate != null ? auditdate.hashCode() : 0);
        result1 = 31 * result1 + (auditLoginId != null ? auditLoginId.hashCode() : 0);
        result1 = 31 * result1 + (result != null ? result.hashCode() : 0);
        result1 = 31 * result1 + (refuseinfo != null ? refuseinfo.hashCode() : 0);
        return result1;
    }

    @Transient
    public boolean back;
    @Transient
    public String method;
    @Transient
    public String errorinfo;
    @Transient
    public int count;
    @Transient
    public int start=0;
    @Transient
    public int pagesize=0;
    @Transient
    public Integer tableid;
}
